package com.example.eduservice.client;


import com.example.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
@Component
@FeignClient(value = "service-vod",fallback = VodFileDegradeFeignClient.class)   //调用服务名称
public interface VodClient {

    //定义调用的方法路径调用
    //根据视频id删除阿里云视频
    //pathvariable要指定名称
    @DeleteMapping("/eduvod/video/removeAlyVideo/{id}")
    public R deleteAlyVideo(@PathVariable("id") String id);

    //删除多个视频
    //加上地址全部路径
    @DeleteMapping("/eduvod/video/deleteBatch")
    public  R deleteBatchVideo(@RequestParam("videoIdList") List<String> videoIdList);


}
